package com.neutech.controller;

import com.neutech.service.DoctorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@CrossOrigin
@RestController//可以省略Respon
public class DoctorController {
    @Autowired
    private DoctorService doctorService;

    @ResponseBody
    @RequestMapping("/doctor")
    public List<Map<String, Object>> doctor()
    {
        return doctorService.queryDoctor();
    }
}
